/*
 ============================================================================
 Name		: TetrisGameDocument.cpp
 Author	  : Vladimir Hozjan
 Copyright   : Copyright (C) 2008 Vladimir Hozjan <vladimir.hozjan@gmail.com>
 Description : CTetrisGameDocument implementation
 ============================================================================
 */

// INCLUDE FILES
#include "TetrisGameAppUi.h"
#include "TetrisGameDocument.h"

// ============================ MEMBER FUNCTIONS ===============================

// -----------------------------------------------------------------------------
// CTetrisGameDocument::NewL()
// Two-phased constructor.
// -----------------------------------------------------------------------------
//
CTetrisGameDocument* CTetrisGameDocument::NewL(CEikApplication& aApp)
	{
	CTetrisGameDocument* self = NewLC(aApp);
	CleanupStack::Pop(self);
	return self;
	}

// -----------------------------------------------------------------------------
// CTetrisGameDocument::NewLC()
// Two-phased constructor.
// -----------------------------------------------------------------------------
//
CTetrisGameDocument* CTetrisGameDocument::NewLC(CEikApplication& aApp)
	{
	CTetrisGameDocument* self = new (ELeave) CTetrisGameDocument(aApp);

	CleanupStack::PushL(self);
	self->ConstructL();
	return self;
	}

// -----------------------------------------------------------------------------
// CTetrisGameDocument::ConstructL()
// Symbian 2nd phase constructor can leave.
// -----------------------------------------------------------------------------
//
void CTetrisGameDocument::ConstructL()
	{
	// No implementation required
	}

// -----------------------------------------------------------------------------
// CTetrisGameDocument::CTetrisGameDocument()
// C++ default constructor can NOT contain any code, that might leave.
// -----------------------------------------------------------------------------
//
CTetrisGameDocument::CTetrisGameDocument(CEikApplication& aApp) :
	CAknDocument(aApp)
	{
	// No implementation required
	}

// ---------------------------------------------------------------------------
// CTetrisGameDocument::~CTetrisGameDocument()
// Destructor.
// ---------------------------------------------------------------------------
//
CTetrisGameDocument::~CTetrisGameDocument()
	{
	// No implementation required
	}

// ---------------------------------------------------------------------------
// CTetrisGameDocument::CreateAppUiL()
// Constructs CreateAppUi.
// ---------------------------------------------------------------------------
//
CEikAppUi* CTetrisGameDocument::CreateAppUiL()
	{
	// Create the application user interface, and return a pointer to it;
	// the framework takes ownership of this object
	return new (ELeave) CTetrisGameAppUi;
	}

// End of File
